#define LOG_TAG "vendor.lyzr.hardware.lytest@1.0-service"
#include <android-base/logging.h>
#include <hidl/HidlTransportSupport.h>
#include <vendor/lyzr/hardware/lytest/1.0/ILyTest.h>
#include <hidl/LegacySupport.h>
#include "LyTest.h"

using ::android::hardware::configureRpcThreadpool;
using ::android::hardware::joinRpcThreadpool;
using ::android::sp;
using ::vendor::lyzr::hardware::lytest::V1_0::implementation::LyTest;
using ::vendor::lyzr::hardware::lytest::V1_0::ILyTest;

int main()
{
    sp<ILyTest> lyTest = new LyTest();
    configureRpcThreadpool(4, true);
    if (lyTest->registerAsService())
    {
        ALOGE("Could not register LyTest 1.1 service.");
        return 1;
    }
    joinRpcThreadpool();// joinRpcThreadpool shouldn't exit

    ALOGE("Service exited!");
    return 1;
}
